<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
 <head>
  <meta http-equiv="content-type" content="text/html; charset=UTF-8">
  <title>清除已经设置的响应body</title>
<link media="all" rel="stylesheet" type="text/css" href="styles/03e73060321a0a848018724a6c83de7f-theme-base.css" />
<link media="all" rel="stylesheet" type="text/css" href="styles/03e73060321a0a848018724a6c83de7f-theme-medium.css" />

 </head>
 <body class="docs"><div class="navbar navbar-fixed-top">
  <div class="navbar-inner clearfix">
    <ul class="nav" style="width: 100%">
      <li style="float: left;"><a href="yaf-response-abstract.appendbody.html">« Yaf_Response_Abstract::appendBody</a></li>
      <li style="float: right;"><a href="yaf-response-abstract.clearheaders.html">Yaf_Response_Abstract::clearHeaders »</a></li>
    </ul>
  </div>
</div>
<div id="breadcrumbs" class="clearfix">
  <ul class="breadcrumbs-container">
    <li><a href="index.html">PHP Manual</a></li>
    <li><a href="class.yaf-response-abstract.html">Yaf_Response_Abstract</a></li>
    <li>清除已经设置的响应body</li>
  </ul>
</div>
<div id="layout">
  <div id="layout-content"><div id="yaf-response-abstract.clearbody" class="refentry">
 <div class="refnamediv">
  <h1 class="refname">Yaf_Response_Abstract::clearBody</h1>
  <p class="verinfo">(Yaf &gt;=1.0.0)</p><p class="refpurpose"><span class="refname">Yaf_Response_Abstract::clearBody</span> &mdash; <span class="dc-title">清除已经设置的响应body</span></p>

 </div>

 <div class="refsect1 description" id="refsect1-yaf-response-abstract.clearbody-description">
  <h3 class="title">说明</h3>
  <div class="methodsynopsis dc-description">
   <span class="modifier">public</span> <span class="methodname"><strong>Yaf_Response_Abstract::clearBody</strong></span>(<span class="methodparam"><span class="type">string</span> <code class="parameter">$key</code><span class="initializer"> = ?</span></span>): <span class="type">bool</span></div>

  <p class="para rdfs-comment">
   清除已经设置的响应body
  </p>
 </div>


 <div class="refsect1 parameters" id="refsect1-yaf-response-abstract.clearbody-parameters">
  <h3 class="title">参数</h3>
  <dl>
   
    <dt>
<code class="parameter">key</code></dt>

    <dd>

     <p class="para">
      the content key, if you don&#039;t specific, then all contents will be
      cleared.
      如果你没选择具体清除哪个key所对应的内容，那所有内容将被清除
      <blockquote class="note"><p><strong class="note">注意</strong>: 
       <p class="para">
       this parameter is introduced as of 2.2.0
      </p>
      </p></blockquote>
     </p>
    </dd>

   
  </dl>

 </div>


 <div class="refsect1 returnvalues" id="refsect1-yaf-response-abstract.clearbody-returnvalues">
  <h3 class="title">返回值</h3>
  <p class="para">

  </p>
 </div>


 <div class="refsect1 seealso" id="refsect1-yaf-response-abstract.clearbody-seealso">
  <h3 class="title">参见</h3>
  <ul class="simplelist">
   <li class="member"><span class="methodname"><a href="yaf-response-abstract.setbody.html" class="methodname" rel="rdfs-seeAlso">Yaf_Response_Abstract::setBody()</a> - 设置响应的Body</span></li>
   <li class="member"><span class="methodname"><a href="yaf-response-abstract.appendbody.html" class="methodname" rel="rdfs-seeAlso">Yaf_Response_Abstract::appendBody()</a> - 往已有的响应body后附加新的内容</span></li>
   <li class="member"><span class="methodname"><a href="yaf-response-abstract.prependbody.html" class="methodname" rel="rdfs-seeAlso">Yaf_Response_Abstract::prependBody()</a> - The prependBody purpose</span></li>
   <li class="member"><span class="methodname"><a href="yaf-response-abstract.getbody.html" class="methodname" rel="rdfs-seeAlso">Yaf_Response_Abstract::getBody()</a> - 获取已经设置的响应body</span></li>
  </ul>
 </div>


</div></div></div></body></html>